"# -*- encoding: utf-8 -*-"
"""
@Project :   quant
@File    :   get_stock_list.py
@Time    :   2019/11/15 13:50
@Author  :   BiKang Peng
@Software:   PyCharm
@Contact :   782222720@qq.com
@License :   (C)Copyright 2017-2018, Liugroup-NLPR-CASIA
@Desc : ==============================================
Life is Short I Use Python!!!                      ===
If this runs wrong,don't ask me,I don't know why;  ===
If this runs right,thank god,and I don't know why. ===
Maybe the answer,my friend,is blowing in the wind. ===
======================================================
"""
''' 
获取A股2015年前上市的公司股票
'''

import os
import sys
import tushare as ts
import pandas as pd
import numpy as np


ts.set_token('52d1d7b3ade4d917050699b12c7f2327fd9c2afa2e21e66f2633a88b')
pro = ts.pro_api()
data = pro.stock_basic(exchange='', list_status='L', fields='ts_code,name,industry,list_date')
data.to_csv('stocklist.csv', encoding='utf_8_sig')



